public class Triangle {
    public String printOneStar(){
        return ("*");
    }
    public String printNumberOfStars(int n){
        if(n<=0){
            System.out.println("The number given is too small");
        }
        String outputString = "";
        for(int i = 0;i<n;i++){
            outputString += "*";
        }
        return  outputString;
    }
    public String drawVerticalLine(int n){
        if(n<=0){
            System.out.println("The number given is too small");
        }
        String outputString = "";
        for(int i = 0;i<n;i++){
            outputString += "*\n";
        }
        return  outputString;
    }
    public String drawRightTriangle(int n){
        if(n<=0){
            System.out.println("The number given is too small");
        }
        String outputString = "";
        for(int i = 0;i<n;i++){
            for(int j = 0;j<=i;j++){
                outputString += "*";
            }
            outputString += "\n";
        }
        return outputString;
    }
}
